package com.example.demo.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 权限表
 * </p>
 *
 * @author hpp
 * @since 2021-09-14
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("sp_permission")
public class Permission extends Model<Permission> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "ps_id", type = IdType.AUTO)
    private Integer psId;

    /**
     * 权限名称
     */
    private String psName;

    /**
     * 父id
     */
    private Integer psPid;

    /**
     * 控制器
     */
    private String psC;

    /**
     * 操作方法
     */
    private String psA;

    /**
     * 权限等级
     */
    private String psLevel;


    @Override
    protected Serializable pkVal() {
        return this.psId;
    }

}
